<?php
/**
 * @author Biju T biju@poornam.com
 *
 */
require_once("classes/interface/ResponseWrapper.php");

class HttpResponseWrapper implements ResponseWrapper{

	public $conf = null;

	public function setResponseStream($conf){
		$this->conf = $conf;
	}
	
	public function getTemplate(){
		//Load Template Manager
		if($this->conf->getConfig('template') != null){
			$tpl_conf =$this->conf->getConfig('template');
			foreach($tpl_conf as $t_conf){
				if($t_conf['active'] == 1){
					$engine = $t_conf['name'];
					$class = $engine.'TemplateManager';
					$conf_file = $t_conf['conf'];
				}
			}
		}
		return new $class($conf_file);
	}
}
?>